{php include pubTemplate('header');}
<!--加载编辑器-->
<script src="{SITE_URL}public/js/editor/xheditor/xheditor.js" type="text/javascript"></script>
<script src="{SITE_URL}public/js/editor/xheditor/ubb.min.js" type="text/javascript"></script>
<script src="{SITE_URL}public/js/editor/xheditor/loadeditor.js" type="text/javascript"></script>

<script type="text/javascript">
$(document).ready(function() {

	//选择一级分类
	$('#oneid').change(function(){
		$("#stwoid").html('<img src="'+siteUrl+'public/image/loading.gif" />');
		var oneid = $(this).children('option:selected').val();  //弹出select的值
		
		if(oneid==0){
			$("#stwoid").html('');
			$("#sthreeid").html('');
		}else{
			$("#sthreeid").html('');
			$.ajax({
				type: "GET",
				url:  "{SITE_URL}index.php?app=group&ac=scate&ts=two&oneid="+oneid,
				success: function(msg){
					$("#stwoid").html(msg);
					
					//选择二级区域
					$('#twoid').change(function(){
						$("#sthreeid").html('<img src="'+siteUrl+'public/image/loading.gif" />');
						var twoid = $(this).children('option:selected').val();  //弹出select的值
						
						if(twoid == 0){
							$("#sthreeid").html('');
						}else{
						
							//ajax
							$.ajax({
								type: "GET",
								url:  "{SITE_URL}index.php?app=group&ac=scate&ts=three&twoid="+twoid,
								success: function(msg){
									$('#sthreeid').html(msg);
								}
							});
						
						}

					});
					
				}
			});
		
		}
		
	});

});
</script>
<!--main-->
<div class="midder">
<div class="mc">
<h1>{$TS_HL[app][1130]}</h1>
<div class="cleft">

<!--{if $TS_USER[user][userid]==''}-->
<div style="font-size:14px;line-height:25px;padding-top:50px;text-align:center;">{$TS_HL[app][1131]}<br /><a href="{SITE_URL}{tsurl('user','login')}">{$TS_HL[app][1132]}</a></div>

<!--{elseif $TS_APP[options][iscreate] == '1'}-->

<div style="font-size:14px;line-height:25px;padding-top:50px;text-align:center;">{$TS_HL[app][1133]}<br /><a href="{SITE_URL}{tsurl('group')}">{$TS_HL[app][1134]}</a></div>

<!--{else}-->

<form method="POST" action="{SITE_URL}index.php?app=group&ac=do&ts=group_add">
<table width="100%">
<tbody>
<tr><td valign="top" align="center" class="pl2">{$TS_HL[app][1135]}</td>
<td><input type="text" value="" maxlength="63" size="31" name="groupname" gtbfieldid="10"><br><br></td></tr>

<tr>
<td valign="top" align="center" class="pl2">{$TS_HL[app][1136]}</td>
<td>
<select id="oneid" name="oneid">
<option value="0">{$TS_HL[app][1137]}</option>
<!--{loop $arrOne $key $item}-->
<option value="{$item[cateid]}">{$item[catename]}</option>
<!--{/loop}-->
</select>
<span id="stwoid"></span>
<span id="sthreeid"></span>
<br /><br />
</td>
</tr>

<tr><td valign="top" align="center" class="pl2">{$TS_HL[app][1138]}</td>
<td><textarea style="width:500px;height:200px;" name="groupdesc" id="editor_mini"></textarea><br><br></td></tr>

<tr><td></td><td>
<label><input type="checkbox" checked="select" disabled="true" name="grp_agreement" id="grp_agreement">{$TS_HL[app][1139]}</label>
<br><br>
</td>
</tr>

<tr><td></td><td>
<input class="submit" type="submit" value="{$TS_HL[app][1140]}" />
</td></tr></tbody>
</table>
</form>

<!--{/if}-->
</div>

<div class="cright">

</div>

</div>

</div>
{template footer}